package com.fyl.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author 冯永龙
 * @date 2020/12/2 8:57
 */
@Controller
public class RedirectController {
    @GetMapping("/{url}")
    public String redirect(@PathVariable("url") String url) {
        return url;
    }

    @GetMapping("/")
    public String index() {
        return "redirect:/productCategory/list";
    }
}
